/*
 * All rights Reserved, Designed By DataDriver
 * Copyright:    DataDriver.Inc
 * Company:      Zhuo Wo Infomation Technology (ShangHai) CO.LTD
 */
package com.sun.condition.config;

import com.sun.condition.MyCondition;
import com.sun.condition.bean.User;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;

@Configuration
@ComponentScan("com.sun")
public class ConditionConfig {


    @Conditional(MyCondition.class)
    @Bean
    public User user() {
        return new User();
    }
}
